/*
 * Body.h
 *
 *  Created on: 05/05/2011
 *      Author: Rafael
 */

#ifndef BODY_H_
#define BODY_H_

#include "math/Rectangle.h"
#include "Component.h"

class Body : public Component{
	bool collision;
	bool damage;
	bool interact;
	bool action;
	bool strike;

	Rectangle collisionBody;
	Point2D collisionCenter;
	Rectangle damageBody;
	Point2D damageCenter;
	Point2D interactPoint;
	Point2D interactCenter;
	Rectangle actionArea;
	Point2D actionCenter;
	Rectangle strikeArea;
	Point2D strikeCenter;
public:
	Body(int id);
	virtual ~Body();

	Rectangle getCollisionBody();
	Rectangle getDamageBody();
    Point2D getInteractPoint();
    Rectangle getActionArea();
    Rectangle getStrikeArea();
    Point2D getShootPoint();
	/*
	 * Getters and Setters
	 */
	Rectangle getStepCollisionArea(Point2D step);
	Rectangle getStepStrikeArea(Point2D step);
    bool getCollision() const;
    Rectangle getRawCollisionArea() const;
    bool getDamage() const;
    Rectangle getRawDamageArea() const;
    bool getInteract() const;
    Point2D getRawInteractPoint() const;
    bool getAction() const;
    Rectangle getRawActionArea() const;
    void setCollision(bool collision);
    void setCollisionBody(Rectangle collisionBody);
    void setDamage(bool damage);
    void setDamageBody(Rectangle damageBody);
    void setInteract(bool listen);
    void setInteractPoint(Point2D listenPoint);
    void setAction(bool talk);
    void setActionArea(Rectangle talkArea);
    Point2D getCollisionCenter() const;
    Point2D getDamageCenter() const;
    Point2D getInteractCenter() const;
    Point2D getActionCenter() const;
    void setCollisionCenter(Point2D collisionCenter);
    void setDamageCenter(Point2D damageCenter);
    void setInteractCenter(Point2D listenCenter);
    void setActionCenter(Point2D talkCenter);
    bool getStrike() const;
    Rectangle getRawStrikeArea() const;
    Point2D getStrikeCenter() const;
    void setStrike(bool strike);
    void setStrikeArea(Rectangle strikeArea);
    void setStrikeCenter(Point2D strikeCenter);
    bool getShoot() const;
    Point2D getShootCenter() const;
    Point2D getRawShootPoint() const;
    void setShoot(bool shoot);
    void setShootCenter(Point2D shootCenter);
    void setShootPoint(Point2D shootPoint);
};

#endif /* BODY_H_ */
